#!/bin/sh
if [ ! -f "/etc/crontabs/root" ]; then 
	echo "1 4 * * * /etc/init.d/chinadns upchnroute" > /etc/crontabs/root
	echo " " >> /etc/crontabs/root
	echo 'root' >> /etc/crontabs/cron.update
else
	cun=`grep 'chinadns' /etc/crontabs/root|grep  'upchnroute'`
	if [ "$cun" = "" ];then
		sed -i 1i\\'1 4 * * * /etc/init.d/chinadns upchnroute' /etc/crontabs/root
	fi
fi
